import request from '@/utils/request'

export function uploadFile(data) {
  return request({
    url: '/upload',
    method: 'post',
    data
  })
}

export function systemConfigEdit(data) {
  return request({
    url: '/system_config_edit',
    method: 'post',
    data
  })
}

export function systemConfig(query) {
  return request({
    url: '/system_config',
    method: 'get',
    params: query
  })
}

export function fetchUserList(query) {
  return request({
    url: '/user_list',
    method: 'get',
    params: query
  })
}

export function fetchLevelList(query) {
  return request({
    url: '/level_user',
    method: 'get',
    params: query
  })
}

export function userEdit(data) {
  return request({
    url: '/user_edit',
    method: 'post',
    data
  })
}

export function fetchShareList(query) {
  return request({
    url: '/share_order',
    method: 'get',
    params: query
  })
}

export function fetchCommissionList(query) {
  return request({
    url: '/commission_order',
    method: 'get',
    params: query
  })
}

export function fetchOrderList(query) {
  return request({
    url: '/order',
    method: 'get',
    params: query
  })
}

export function fetchProductList(query) {
  return request({
    url: '/product',
    method: 'get',
    params: query
  })
}

export function productCateEdit(data) {
  return request({
    url: '/product_cate_edit',
    method: 'post',
    data
  })
}

export function fetchCateList(query) {
  return request({
    url: '/product_cate',
    method: 'get',
    params: query
  })
}

export function fetchAccountList(query) {
  return request({
    url: '/account',
    method: 'get',
    params: query
  })
}

export function fetchWithdrawalList(query) {
  return request({
    url: '/withdrawal',
    method: 'get',
    params: query
  })
}

export function productCateUpdate(data) {
  return request({
    url: '/product_cate_update',
    method: 'post',
    data
  })
}

export function productEdit(data) {
  return request({
    url: '/product_edit',
    method: 'post',
    data
  })
}

export function productMarket(data) {
  return request({
    url: '/market',
    method: 'post',
    data
  })
}

export function productUpdate(data) {
  return request({
    url: '/product_update',
    method: 'post',
    data
  })
}

export function commissionDetails(data) {
  return request({
    url: '/commission_details',
    method: 'post',
    data
  })
}

export function commissionAgain(data) {
  return request({
    url: '/commission_again',
    method: 'post',
    data
  })
}

export function withdrawalExamine(data) {
  return request({
    url: '/withdrawal_examine',
    method: 'post',
    data
  })
}

export function accountEdit(data) {
  return request({
    url: '/account_edit',
    method: 'post',
    data
  })
}

export function userIncome(query) {
  return request({
    url: '/user_income',
    method: 'get',
    params: query
  })
}

export function adjustBalance(data) {
  return request({
    url: '/adjust_balance',
    method: 'post',
    data
  })
}

export function userRecommend(query) {
  return request({
    url: '/user_recommend',
    method: 'get',
    params: query
  })
}

export function accountAuthUrl(query) {
  return request({
    url: '/account_auth_url',
    method: 'get',
    params: query
  })
}

export function accountRefresh(data) {
  return request({
    url: '/account_refresh',
    method: 'post',
    data
  })
}

export function editPassWord(data) {
  return request({
    url: '/edit_password',
    method: 'post',
    data
  })
}

export function commentUserList(query) {
  return request({
    url: '/user_recommend',
    method: 'get',
    params: query
  })
}

export function getBalance(query) {
  return request({
    url: '/balance',
    method: 'get',
    params: query
  })
}

export function getDhhList(query) {
  return request({
    url: '/goods_list',
    method: 'get',
    params: query
  })
}

export function geturlList(query) {
  return request({
    url: '/goods_urls',
    method: 'get',
    params: query
  })
}

export function getMaskListFacth(query) {
  return request({
    url: '/task_list',
    method: 'get',
    params: query
  })
}

export function getPoolListFacth(query) {
  return request({
    url: '/pool_list',
    method: 'get',
    params: query
  })
}

export function getPoolGoodsListFacth(query) {
  return request({
    url: '/pool_goods',
    method: 'get',
    params: query
  })
}

export function getAdvListFacth(query) {
  return request({
    url: '/advert_list',
    method: 'get',
    params: query
  })
}

export function addAdvFacth(query) {
  return request({
    url: '/create_advert',
    method: 'POST',
    params: query
  })
}

export function getDataOrder(query) {
  return request({
    url: '/order_summary',
    method: 'get',
    params: query
  })
}

export function changeGoods(query) {
  return request({
    url: '/goods_update',
    method: 'POST',
    params: query
  })
}

export function getAllPoos(query) {
  return request({
    url: '/all_pool',
    method: 'get',
    params: query
  })
}

export function changeAdv(query) {
  return request({
    url: '/advert_update',
    method: 'POST',
    params: query
  })
}

export function updateDhh(query) {
  return request({
    url: '/goods_edit',
    method: 'POST',
    params: query
  })
}

export function updatePools(query) {
  return request({
    url: '/update_goods',
    method: 'POST',
    params: query
  })
}

export function getSettleFetch(query) {
  return request({
    url: '/withdrawal_export',
    method: 'POST',
    params: query
  })
}

export function sendTransferCode(query) {
  return request({
    url: '/confirm_transfer',
    method: 'POST',
    params: query
  })
}
